﻿<Window x:Class="Translator.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:avalonEdit="http://icsharpcode.net/sharpdevelop/avalonedit"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="MainWindow" Height="359.6" Width="547.4">
    <Grid>
        <TabControl Margin="0,0,0,-0.2">
            <TabItem Header="Семантика">
                <Grid Background="#FFE5E5E5" >
                    <Grid.RowDefinitions>
                        <RowDefinition />
                        <RowDefinition />
                        <RowDefinition />
                        <RowDefinition />
                        <RowDefinition />
                        <RowDefinition />
                        <RowDefinition />
                        <RowDefinition />
                        <RowDefinition />
                        <RowDefinition />
                        <RowDefinition />
                        <RowDefinition />
                    </Grid.RowDefinitions>
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="200" />
                        <ColumnDefinition Width="2*" />
                    </Grid.ColumnDefinitions>
                   

                    <TextBlock Grid.Column="0" Grid.Row="0" >E :: = Num</TextBlock>
                        <TextBox Grid.Column="1" Grid.Row="0"/>

                        <TextBlock Grid.Column="0" Grid.Row="1" >E :: = Bool</TextBlock>
                        <TextBox Grid.Column="1" Grid.Row="1"/>

                        <TextBlock Grid.Column="0" Grid.Row="2">E :: = I</TextBlock>
                        <TextBox Grid.Column="1" Grid.Row="2"/>

                        <TextBlock Grid.Column="0" Grid.Row="3">E :: = read</TextBlock>
                        <TextBox Grid.Column="1" Grid.Row="3"/>

                        <TextBlock Grid.Column="0" Grid.Row="4">E :: = not E</TextBlock>
                        <TextBox Grid.Column="1" Grid.Row="4"/>

                        <TextBlock Grid.Column="0" Grid.Row="5" >E :: = E1 = E2</TextBlock>
                        <TextBox Grid.Column="1" Grid.Row="5" />

                        <TextBlock Grid.Column="0" Grid.Row="6">E :: = E1 + E2</TextBlock>
                        <TextBox Grid.Column="1" Grid.Row="6"/>

                        <TextBlock Grid.Column="0" Grid.Row="7">C :: = I := E</TextBlock>
                        <TextBox Grid.Column="1" Grid.Row="7"/>

                        <TextBlock Grid.Column="0" Grid.Row="8">C :: = output E</TextBlock>
                        <TextBox Grid.Column="1" Grid.Row="8"/>

                        <TextBlock Grid.Column="0" Grid.Row="9">C :: = if E then C1 else C2</TextBlock>
                        <TextBox Grid.Column="1" Grid.Row="9"/>

                        <TextBlock Grid.Column="0" Grid.Row="10">C :: = C1;C2</TextBlock>
                        <TextBox Grid.Column="1" Grid.Row="10"/>
                        
                    <Button 
                        Name="Submit"
                        Content="Submit"
                        Grid.Column="0"
                        Grid.Row="11"
                        Click="Submit_Click_1"></Button>
                </Grid>

            </TabItem>
            <TabItem Header="Программа">
                <Grid Background="#FFE5E5E5">
                    <Grid.RowDefinitions>
                        <RowDefinition />
                        <RowDefinition Height="40" />
                    </Grid.RowDefinitions>
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="2*" />
                        <ColumnDefinition Width="2*" />
                        <ColumnDefinition Width="90" />
                    </Grid.ColumnDefinitions>
                    <avalonEdit:TextEditor Grid.Row="0" Grid.Column ="0" 
				        Name="programEditor"
				        FontFamily="Consolas"
				        FontSize="10pt"
				        SyntaxHighlighting="pascal" 
			>
                    </avalonEdit:TextEditor>
                    <avalonEdit:TextEditor Grid.Row="0" Grid.Column ="1" 
				        Name="lambdaEditor"
				        FontFamily="Consolas"
				        FontSize="10pt"
				        SyntaxHighlighting="C#" 
			>
                    </avalonEdit:TextEditor>

                    <Button 
                        Grid.Row="0"
                        Grid.Column="2"
                        Name="Translate"
                        Margin="0.4,0,0.2,0" 
                        Height="25"
                        VerticalAlignment="Top"
                        Click="Translate_Click_1">Транслировать
                    </Button>
                    <Button 
                        Grid.Row="0"
                        Grid.Column="2"
                        Name="Execute"
                        Margin="0.4,30,0.2,0" 
                        Height="25"
                        VerticalAlignment="Top"
                        Click="Execute_Click_1"
                        >Выполнить
                        </Button>

                    <TextBlock Grid.Column="0" Grid.Row="1" > Введите аргменты: </TextBlock>
                    <TextBox Grid.Column="1" Grid.Row="1" Name="Arguments"/>
                </Grid>
            </TabItem>
            <TabItem Header="Результат">
                <Grid Background="#FFE5E5E5">
                    <Grid.RowDefinitions>
                        <RowDefinition Height="80"/>
                        <RowDefinition Height="10"/>
                        <RowDefinition Height="2*"/>
                    </Grid.RowDefinitions>
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition />
                    </Grid.ColumnDefinitions>
                    <Border Grid.Row="0" Grid.Column="0" BorderThickness="2"  BorderBrush="Black">
                        <ScrollViewer >
                            <TextBlock Name="ExecutionResult"/>
                        </ScrollViewer>
                    </Border>
                    <Border Grid.Row="2" Grid.Column="0" BorderThickness="2"  BorderBrush="Black">
                        <ScrollViewer >
                            <TextBlock Name="Logs"/>
                        </ScrollViewer>
                    </Border>
                </Grid>
                    
                     
            </TabItem>
        </TabControl>

    </Grid>
</Window>
